<!DOCTYPE html>
<html lang="zh-CN">
  <head>
  <meta charset="UTF-8">
  <meta 
    name="viewport"
    content="width=device-width, initial-scale=1.0, minimum-scale=1.0">
  <meta 
    http-equiv="X-UA-Compatible" 
    content="ie=edge">
  <meta 
    name="theme-color" 
    content="#fff" 
    id="theme-color">
  <meta 
    name="description" 
    content="hexoDemo用于介绍如何使用hexo">
  <link 
    rel="icon" 
    href="/">
  <title>VS Code的使用积累</title>
  
    
      <meta 
        property="og:title" 
        content="VS Code的使用积累">
    
    
      <meta 
        property="og:url" 
        content="https://zwl5670.gitee.io/2000/01/01/00-%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/VS%20Code%E7%9A%84%E4%BD%BF%E7%94%A8%E7%A7%AF%E7%B4%AF/index.html">
    
    
      <meta 
        property="og:img" 
        content="https://img.songhn.com/img/Y67gdd.png">
    
    
      <meta 
        property="og:img" 
        content="hexoDemo用于介绍如何使用hexo">
    
    
      <meta 
        property="og:type" 
        content="article">
      <meta 
        property="og:article:published_time" 
        content="2000-01-01">
      <meta 
        property="og:article:modified_time" 
        content="2023-03-14">
      <meta 
        property="og:article:author" 
        content="zwl5670">
      
        
          <meta 
            property="og:article:tag" 
            content="前端工具">
        
      
    
  
  
  <link rel="preload" href="//at.alicdn.com/t/font_1946621_i1kgafibvw.css" as="style" >
  <link rel="preload" href="//at.alicdn.com/t/font_1952792_89b4ac4k4up.css" as="style" >
  <link rel="preload" href="/css/main.css" as="style" >
  
  <link rel="modulepreload" href="//instant.page/5.1.0">
  
  <link rel="stylesheet" href="/css/main.css">
  
  <link rel="stylesheet" href="//at.alicdn.com/t/font_1946621_i1kgafibvw.css">
  
  <link rel="stylesheet" href="//at.alicdn.com/t/font_1952792_89b4ac4k4up.css">
  
  
  
    <link rel="stylesheet" href="/js/lib/lightbox/baguetteBox.min.css">
  
  <script>
    function loadScript(url, cb) {
      var script = document.createElement('script');
      script.src = url;
      if (cb) script.onload = cb;
      script.async = true;
      document.body.appendChild(script);
    }
    function loadCSS(href, data, attr) {
      var sheet = document.createElement('link');
      sheet.ref = 'stylesheet';
      sheet.href = href;
      sheet.dataset[data] = attr;
      document.head.appendChild(sheet);
    }
    function changeCSS(cssFile, data, attr) {
      var oldlink = document.querySelector(data);
      var newlink = document.createElement("link");
      newlink.setAttribute("rel", "stylesheet");
      newlink.setAttribute("href", cssFile);
      newlink.dataset.prism = attr;
      document.head.replaceChild(newlink, oldlink);
    }
  </script>
  
    
  
  <script>
    // control reverse button
    var reverseDarkList = {
      dark: 'light',
      light: 'dark'
    };
    var themeColor = {
      dark: '#1c1c1e',
      light: '#fff'
    }
    // get the data of css prefers-color-scheme
    var getCssMediaQuery = function() {
      return window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
    };
    // reverse current darkmode setting function
    var reverseDarkModeSetting = function() {
      var setting = localStorage.getItem('user-color-scheme');
      if(reverseDarkList[setting]) {
        setting = reverseDarkList[setting];
      } else if(setting === null) {
        setting = reverseDarkList[getCssMediaQuery()];
      } else {
        return;
      }
      localStorage.setItem('user-color-scheme', setting);
      return setting;
    };
    // apply current darkmode setting
  </script>
  
    <script>
      var setDarkmode = function(mode) {
      var setting = mode || localStorage.getItem('user-color-scheme');
      if(setting === getCssMediaQuery()) {
        document.documentElement.removeAttribute('data-user-color-scheme');
        localStorage.removeItem('user-color-scheme');
        document.getElementById('theme-color').content = themeColor[setting];
        document.getElementById('theme-color').dataset.mode = setting;
      } else if(reverseDarkList[setting]) {
        document.documentElement.setAttribute('data-user-color-scheme', setting);
        document.getElementById('theme-color').content = themeColor[setting];
        document.getElementById('theme-color').dataset.mode = setting;
      } else {
        document.documentElement.removeAttribute('data-user-color-scheme');
        localStorage.removeItem('user-color-scheme');
        document.getElementById('theme-color').content = themeColor[getCssMediaQuery()];
        document.getElementById('theme-color').dataset.mode = getCssMediaQuery();
      }
    };
    setDarkmode();
    </script>
  
  
  
    <link rel="preload" href="/js/lib/lightbox/baguetteBox.min.js" as="script">
    <link rel="preload" href="/js/lib/lightbox/baguetteBox.min.css" as="style" >
  
  
    <link rel="preload" href="/js/lib/lozad.min.js" as="script">
  
  
  
  
  
  
<meta name="generator" content="Hexo 6.3.0"></head>

  <body>
    <div class="wrapper">
       
      <nav class="navbar">
  <div class="navbar-logo">
    <a class="navbar-logo-main" href="/">
      
      <span class="navbar-logo-dsc">前端面试</span>
      </a>
  </div>
  <div class="navbar-menu">
    
      <a 
        href="/" 
        class="navbar-menu-item">
        
          首页
        
      </a>
    
      <a 
        href="/archives" 
        class="navbar-menu-item">
        
          归档
        
      </a>
    
      <a 
        href="/tags" 
        class="navbar-menu-item">
        
          标签
        
      </a>
    
      <a 
        href="/categories" 
        class="navbar-menu-item">
        
          分类
        
      </a>
    
      <a 
        href="/about" 
        class="navbar-menu-item">
        
          关于
        
      </a>
    
      <a 
        href="/links" 
        class="navbar-menu-item">
        
          友链
        
      </a>
    
    <button 
      class="navbar-menu-item darknavbar navbar-menu-btn" 
      aria-label="Toggle dark mode"
      id="dark">
      <i class="iconfont icon-weather"></i>
    </button>
    <button 
      class="navbar-menu-item searchnavbar navbar-menu-btn" 
      aria-label="Toggle search"
      id="search">
      <!-- <i 
        class="iconfont icon-search" 
        style="font-size: 1.2rem; font-weight: 400;">
      </i> -->
      <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img"
        class="iconify iconify--ion" width="28" height="28" preserveAspectRatio="xMidYMid meet" viewBox="0 0 512 512">
        <path fill="none" stroke="currentColor" stroke-miterlimit="10" stroke-width="28"
          d="M256 80a176 176 0 1 0 176 176A176 176 0 0 0 256 80Z"></path>
        <path fill="none" stroke="currentColor" stroke-miterlimit="10" stroke-width="28"
          d="M232 160a72 72 0 1 0 72 72a72 72 0 0 0-72-72Z"></path>
        <path fill="none" stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="28"
          d="M283.64 283.64L336 336"></path>
      </svg>
    </button>
  </div>
</nav> 
      
      <div 
        id="local-search" 
        style="display: none">
        <input
          class="navbar-menu-item"
          id="search-input"
          placeholder="请输入搜索内容..." />
        <div id="search-content"></div>
      </div>
      
      <div class="section-wrap">
        <div class="container">
          <div class="columns">
            <aside class="left-column">
              
              <div class="card card-author">
                
  <img 
    src="https://img.songhn.com/img/Y67gdd.png" 
    class="author-img"
    width="88"
    height="88"
    alt="author avatar">

<p class="author-name">zwl5670</p>
<p class="author-description">前端学习资料</p>
<div class="author-message">
  <a 
    class="author-posts-count" 
    href="/archives">
    <span>215</span>
    <span>文章</span>
  </a>
  <a 
    class="author-categories-count" 
    href="/categories">
    <span>14</span>
    <span>分类</span>
  </a>
  <a 
    class="author-tags-count" 
    href="/tags">
    <span>14</span>
    <span>标签</span>
  </a>
</div>

              </div>
               <div class="sticky-tablet">
  
  
    <article class="display-when-two-columns spacer">
      <div class="card card-content toc-card">
        <div class="toc-header">
  <i 
    class="iconfont icon-menu" 
    style="padding-right: 2px;">
  </i>目录
</div>
<ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E8%A7%81%E9%85%8D%E7%BD%AE"><span class="toc-text">常见配置</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E8%A7%81%E6%93%8D%E4%BD%9C"><span class="toc-text">常见操作</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%A6%82%E4%BD%95%E6%9F%A5%E7%9C%8B%E4%BB%A3%E7%A0%81%E7%BB%93%E6%9E%84"><span class="toc-text">如何查看代码结构</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%9C%A8%E6%9C%AC%E5%9C%B0%E5%BC%80%E5%90%AF%E6%9C%8D%E5%8A%A1%E5%99%A8"><span class="toc-text">在本地开启服务器</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E7%94%A8%E6%8F%92%E4%BB%B6"><span class="toc-text">常用插件</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#sftp%EF%BC%9A%E6%96%87%E4%BB%B6%E4%BC%A0%E8%BE%93"><span class="toc-text">sftp：文件传输</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Sass-Formatter"><span class="toc-text">Sass Formatter</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Code-Outline%EF%BC%9A%E6%98%BE%E7%A4%BA%E4%BB%A3%E7%A0%81%E7%BB%93%E6%9E%84"><span class="toc-text">Code Outline：显示代码结构</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#vscode-fileheader%EF%BC%9A%E6%B7%BB%E5%8A%A0%E9%A1%B6%E9%83%A8%E6%B3%A8%E9%87%8A%E6%A8%A1%E6%9D%BF-%E7%AD%BE%E5%90%8D"><span class="toc-text">vscode-fileheader：添加顶部注释模板(签名)</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Express"><span class="toc-text">Express</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Copy-Relative-Path"><span class="toc-text">Copy Relative Path</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#open-in-browser"><span class="toc-text">open in browser</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Auto-Rename-Tag"><span class="toc-text">Auto Rename Tag</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#highlight-icemode%EF%BC%9A%E9%80%89%E4%B8%AD%E7%9B%B8%E5%90%8C%E7%9A%84%E4%BB%A3%E7%A0%81%E6%97%B6%EF%BC%8C%E8%AE%A9%E9%AB%98%E4%BA%AE%E6%98%BE%E7%A4%BA%E6%9B%B4%E5%8A%A0%E6%98%8E%E6%98%BE%E3%80%90%E8%8D%90%E3%80%91"><span class="toc-text">highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#highlight-words%EF%BC%9A%E5%85%A8%E5%B1%80%E9%AB%98%E4%BA%AE%EF%BC%88%E8%B7%A8%E6%96%87%E4%BB%B6%E5%A4%9A%E8%89%B2%E5%BD%A9%EF%BC%89"><span class="toc-text">highlight-words：全局高亮（跨文件多色彩）</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#color-exchange%EF%BC%9A%E9%A2%9C%E8%89%B2%E6%A0%BC%E5%BC%8F%E8%BD%AC%E6%8D%A2%E3%80%90%E8%8D%90%E3%80%91"><span class="toc-text">color-exchange：颜色格式转换【荐】</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#Vue-%E7%9B%B8%E5%85%B3%E7%9A%84%E6%8F%92%E4%BB%B6"><span class="toc-text">Vue 相关的插件</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#vetur%EF%BC%9Avue-%E6%96%87%E4%BB%B6%E7%9A%84%E5%9F%BA%E6%9C%AC%E8%AF%AD%E6%B3%95%E9%AB%98%E4%BA%AE"><span class="toc-text">vetur：vue 文件的基本语法高亮</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%8F%82%E8%80%83%E9%93%BE%E6%8E%A5"><span class="toc-text">参考链接</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E7%94%A8%E5%BF%AB%E6%8D%B7%E9%94%AE"><span class="toc-text">常用快捷键</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%A6%82%E4%BD%95%E5%90%8C%E6%97%B6%E6%89%93%E5%BC%80%E5%A4%9A%E4%B8%AA%E7%AA%97%E5%8F%A3"><span class="toc-text">如何同时打开多个窗口</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E9%97%AE%E9%A2%98"><span class="toc-text">问题</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%8F%82%E8%80%83%E9%93%BE%E6%8E%A5-1"><span class="toc-text">参考链接</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%9F%90%E7%BD%91%E5%8F%8B%E7%9A%84VS-Code-%E6%8F%92%E4%BB%B6%E6%88%AA%E5%9B%BE"><span class="toc-text">某网友的VS Code 插件截图</span></a></li></ol></li></ol>
      </div>
    </article>
  
  
  <article class="card card-content categories-widget">
    <div class="categories-card">
  <div class="categories-header">
    <i 
      class="iconfont icon-fenlei" 
      style="padding-right: 2px;">
    </i>分类
  </div>
  <div class="categories-list">
    
      <a href="/categories/%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/">
        <div class="categories-list-item">
          前端工具
          <span class="categories-list-item-badge">13</span>
        </div>
      </a>
    
      <a href="/categories/CSS%E5%9F%BA%E7%A1%80/">
        <div class="categories-list-item">
          CSS基础
          <span class="categories-list-item-badge">18</span>
        </div>
      </a>
    
      <a href="/categories/CSS%E8%BF%9B%E9%98%B6/">
        <div class="categories-list-item">
          CSS进阶
          <span class="categories-list-item-badge">9</span>
        </div>
      </a>
    
      <a href="/categories/HTML/">
        <div class="categories-list-item">
          HTML
          <span class="categories-list-item-badge">12</span>
        </div>
      </a>
    
      <a href="/categories/JS%E5%9F%BA%E7%A1%80/">
        <div class="categories-list-item">
          JS基础
          <span class="categories-list-item-badge">56</span>
        </div>
      </a>
    
      <a href="/categories/JS%E5%9F%BA%E7%A1%80ES6/">
        <div class="categories-list-item">
          JS基础ES6
          <span class="categories-list-item-badge">10</span>
        </div>
      </a>
    
      <a href="/categories/JS%E5%9F%BA%E7%A1%80%E5%BC%82%E6%AD%A5/">
        <div class="categories-list-item">
          JS基础异步
          <span class="categories-list-item-badge">11</span>
        </div>
      </a>
    
      <a href="/categories/JS%E8%BF%9B%E9%98%B6/">
        <div class="categories-list-item">
          JS进阶
          <span class="categories-list-item-badge">11</span>
        </div>
      </a>
    
      <a href="/categories/%E7%A7%BB%E5%8A%A8web/">
        <div class="categories-list-item">
          移动web
          <span class="categories-list-item-badge">3</span>
        </div>
      </a>
    
      <a href="/categories/CSS%E5%92%8CDOM/">
        <div class="categories-list-item">
          CSS和DOM
          <span class="categories-list-item-badge">6</span>
        </div>
      </a>
    
      <a href="/categories/Node/">
        <div class="categories-list-item">
          Node
          <span class="categories-list-item-badge">16</span>
        </div>
      </a>
    
      <a href="/categories/Vue%E5%9F%BA%E7%A1%80/">
        <div class="categories-list-item">
          Vue基础
          <span class="categories-list-item-badge">15</span>
        </div>
      </a>
    
      <a href="/categories/%E6%80%A7%E8%83%BD%E4%BC%98%E5%8C%96/">
        <div class="categories-list-item">
          性能优化
          <span class="categories-list-item-badge">7</span>
        </div>
      </a>
    
      <a href="/categories/%E5%89%8D%E7%AB%AF%E5%B7%A5%E7%A8%8B%E5%8C%96/">
        <div class="categories-list-item">
          前端工程化
          <span class="categories-list-item-badge">8</span>
        </div>
      </a>
    
  </div>
</div>
  </article>
  
  <article class="card card-content tags-widget">
    <div class="tags-card">
  <div class="tags-header">
    <i 
      class="iconfont icon-biaoqian" 
      style="padding-right: 2px;">
    </i>热门标签
  </div>
  <div class="tags-list">
    
      <a 
        href="/tags/JS%E5%9F%BA%E7%A1%80/" 
        title="JS基础">
        <div class="tags-list-item">JS基础</div>
      </a>
    
      <a 
        href="/tags/CSS%E5%9F%BA%E7%A1%80/" 
        title="CSS基础">
        <div class="tags-list-item">CSS基础</div>
      </a>
    
      <a 
        href="/tags/Node/" 
        title="Node">
        <div class="tags-list-item">Node</div>
      </a>
    
      <a 
        href="/tags/Vue%E5%9F%BA%E7%A1%80/" 
        title="Vue基础">
        <div class="tags-list-item">Vue基础</div>
      </a>
    
      <a 
        href="/tags/%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/" 
        title="前端工具">
        <div class="tags-list-item">前端工具</div>
      </a>
    
      <a 
        href="/tags/HTML/" 
        title="HTML">
        <div class="tags-list-item">HTML</div>
      </a>
    
      <a 
        href="/tags/JS%E8%BF%9B%E9%98%B6/" 
        title="JS进阶">
        <div class="tags-list-item">JS进阶</div>
      </a>
    
      <a 
        href="/tags/JS%E5%9F%BA%E7%A1%80%E5%BC%82%E6%AD%A5/" 
        title="JS基础异步">
        <div class="tags-list-item">JS基础异步</div>
      </a>
    
      <a 
        href="/tags/JS%E5%9F%BA%E7%A1%80ES6/" 
        title="JS基础ES6">
        <div class="tags-list-item">JS基础ES6</div>
      </a>
    
      <a 
        href="/tags/CSS%E8%BF%9B%E9%98%B6/" 
        title="CSS进阶">
        <div class="tags-list-item">CSS进阶</div>
      </a>
    
      <a 
        href="/tags/%E5%89%8D%E7%AB%AF%E5%B7%A5%E7%A8%8B%E5%8C%96/" 
        title="前端工程化">
        <div class="tags-list-item">前端工程化</div>
      </a>
    
      <a 
        href="/tags/%E6%80%A7%E8%83%BD%E4%BC%98%E5%8C%96/" 
        title="性能优化">
        <div class="tags-list-item">性能优化</div>
      </a>
    
      <a 
        href="/tags/CSS%E5%92%8CDOM/" 
        title="CSS和DOM">
        <div class="tags-list-item">CSS和DOM</div>
      </a>
    
      <a 
        href="/tags/%E7%A7%BB%E5%8A%A8web/" 
        title="移动web">
        <div class="tags-list-item">移动web</div>
      </a>
    
  </div>
</div>
  </article>
  
  
</div>
            </aside>
            <main class="main-column">
              
<article class="card card-content">
  <header>
    <h1 class="post-title">
      VS Code的使用积累
    </h1>
  </header>
  <div class="post-meta post-show-meta">
    <time datetime="1999-12-31T16:00:00.000Z">
      <i 
        class="iconfont icon-calendar" 
        style="margin-right: 2px;">
      </i>
      <span>2000-01-01</span>
    </time>
    
      <span class="dot"></span>
      
        <a 
          href="/categories/%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/" 
          class="post-meta-link">
          前端工具
        </a>
      
    
    
      <span class="dot"></span>
      <span>1.3k 字</span>
    
  </div>
  
    <div 
      class="post-meta post-show-meta" 
      style="margin-top: -10px;">
      <div style="display: flex; align-items: center;">
        <i 
          class="iconfont icon-biaoqian" 
          style="margin-right: 2px; font-size: 1.15rem;">
        </i>
        
          
          <a 
            href="/tags/%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/" 
            class="post-meta-link">
            前端工具
          </a>
        
      </div>
    </div>
  
  </header>
  <div 
    id="section" 
    class="post-content">
    <h2 id="常见配置"><a href="#常见配置" class="headerlink" title="常见配置"></a>常见配置</h2><p><strong>自动保存</strong>：</p>
<pre class="highlight"><span class="line">&quot;files.autoSave&quot;: &quot;onFocusChange&quot;</span><br></pre>

<p>参考链接：<a target="_blank" rel="noopener" href="https://blog.csdn.net/WestLonly/article/details/78048049">https://blog.csdn.net/WestLonly/article/details/78048049</a></p>
<p><strong>在新的窗口中打开文件</strong>：</p>
<pre class="highlight"><span class="line"><span class="attr">&quot;workbench.editor.enablePreview&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">false</span></span><span class="punctuation">,</span></span><br></pre>

<h2 id="常见操作"><a href="#常见操作" class="headerlink" title="常见操作"></a>常见操作</h2><h3 id="如何查看代码结构"><a href="#如何查看代码结构" class="headerlink" title="如何查看代码结构"></a>如何查看代码结构</h3><ul>
<li><p>方法一：「Cmd + Shift + O」</p>
</li>
<li><p>方法二：安装插件<code>Code Outline</code></p>
</li>
</ul>
<p>参考链接：<a target="_blank" rel="noopener" href="https://www.zhihu.com/question/264045094">https://www.zhihu.com/question/264045094</a></p>
<h3 id="在本地开启服务器"><a href="#在本地开启服务器" class="headerlink" title="在本地开启服务器"></a>在本地开启服务器</h3><pre class="highlight"><span class="line"><span class="comment"># 安装</span></span><br><span class="line">npm install -g live-server</span><br><span class="line"></span><br><span class="line"><span class="comment"># 启动</span></span><br><span class="line">live-server</span><br></pre>


<p>参考链接：<a target="_blank" rel="noopener" href="http://www.cnblogs.com/1zhk/p/5699379.html">Visual Studio Code + live-server编辑和浏览HTML网页</a></p>
<h2 id="常用插件"><a href="#常用插件" class="headerlink" title="常用插件"></a>常用插件</h2><p>方式一：打开VS Code，左侧有五个按钮，点击最下方的按钮，然后就可以开始安装相应的插件了。</p>
<p>方式二：在vscode中输入快捷键「ctrl+shift+P」，弹出指令窗口，输入<code>extension:install</code>，回车，左侧即打开扩展安装的界面。</p>
<h3 id="sftp：文件传输"><a href="#sftp：文件传输" class="headerlink" title="sftp：文件传输"></a>sftp：文件传输</h3><p>输入快捷键「ctrl+shift+P」，弹出指令窗口，输入<code>sftp:config</code>，回车，当前工作工程的<code>.vscode</code>文件夹下就会自动生成一个<code>sftp.json</code>文件，我们需要在这个文件里配置的是：</p>
<ul>
<li><p><code>host</code>：服务器的IP地址</p>
</li>
<li><p><code>username</code>：工作站自己的用户名</p>
</li>
<li><p><code>privateKeyPath</code>：存放在本地的已配置好的用于登录工作站的密钥文件（也可以是ppk文件）</p>
</li>
<li><p><code>remotePath</code>：工作站上与本地工程同步的文件夹路径，需要和本地工程文件根目录同名，且在使用sftp上传文件之前，要手动在工作站上mkdir生成这个根目录</p>
</li>
<li><p><code>ignore</code>：指定在使用sftp: sync to remote的时候忽略的文件及文件夹，注意每一行后面有逗号，最后一行没有逗号</p>
</li>
</ul>
<p>举例如下：(注意，其中的注释不能保留)</p>
<pre class="highlight"><span class="line"><span class="punctuation">&#123;</span></span><br><span class="line">    <span class="attr">&quot;host&quot;</span><span class="punctuation">:</span> <span class="string">&quot;&quot;</span><span class="punctuation">,</span>     <span class="comment">//服务器ip</span></span><br><span class="line">    <span class="attr">&quot;port&quot;</span><span class="punctuation">:</span> <span class="number">22</span><span class="punctuation">,</span>     <span class="comment">//端口，sftp模式是22</span></span><br><span class="line">    <span class="attr">&quot;username&quot;</span><span class="punctuation">:</span> <span class="string">&quot;&quot;</span><span class="punctuation">,</span> <span class="comment">//用户名</span></span><br><span class="line">    <span class="attr">&quot;password&quot;</span><span class="punctuation">:</span> <span class="string">&quot;&quot;</span><span class="punctuation">,</span> <span class="comment">//密码</span></span><br><span class="line">    <span class="attr">&quot;protocol&quot;</span><span class="punctuation">:</span> <span class="string">&quot;sftp&quot;</span><span class="punctuation">,</span> <span class="comment">//模式</span></span><br><span class="line">    <span class="attr">&quot;agent&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">null</span></span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;privateKeyPath&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">null</span></span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;passphrase&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">null</span></span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;passive&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">false</span></span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;interactiveAuth&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">false</span></span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;remotePath&quot;</span><span class="punctuation">:</span> <span class="string">&quot;/root/node/build/&quot;</span><span class="punctuation">,</span>  <span class="comment">//服务器上的文件地址</span></span><br><span class="line">    <span class="attr">&quot;context&quot;</span><span class="punctuation">:</span> <span class="string">&quot;./server/build&quot;</span><span class="punctuation">,</span>        <span class="comment">//本地的文件地址</span></span><br><span class="line"></span><br><span class="line">    <span class="attr">&quot;uploadOnSave&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">true</span></span><span class="punctuation">,</span>   <span class="comment">//监听保存并上传</span></span><br><span class="line">    <span class="attr">&quot;syncMode&quot;</span><span class="punctuation">:</span> <span class="string">&quot;update&quot;</span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;watcher&quot;</span><span class="punctuation">:</span> <span class="punctuation">&#123;</span>            <span class="comment">//监听外部文件</span></span><br><span class="line">        <span class="attr">&quot;files&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">false</span></span><span class="punctuation">,</span>     <span class="comment">//外部文件的绝对路径</span></span><br><span class="line">        <span class="attr">&quot;autoUpload&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">false</span></span><span class="punctuation">,</span></span><br><span class="line">        <span class="attr">&quot;autoDelete&quot;</span><span class="punctuation">:</span> <span class="literal"><span class="keyword">false</span></span></span><br><span class="line">    <span class="punctuation">&#125;</span><span class="punctuation">,</span></span><br><span class="line">    <span class="attr">&quot;ignore&quot;</span><span class="punctuation">:</span> <span class="punctuation">[</span>             <span class="comment">//忽略项</span></span><br><span class="line">        <span class="string">&quot;**/.vscode/**&quot;</span><span class="punctuation">,</span></span><br><span class="line">        <span class="string">&quot;**/.git/**&quot;</span><span class="punctuation">,</span></span><br><span class="line">        <span class="string">&quot;**/.DS_Store&quot;</span></span><br><span class="line">    <span class="punctuation">]</span></span><br><span class="line"><span class="punctuation">&#125;</span></span><br></pre>


<h3 id="Sass-Formatter"><a href="#Sass-Formatter" class="headerlink" title="Sass Formatter"></a>Sass Formatter</h3><p>Sass 文件格式化。</p>
<h3 id="Code-Outline：显示代码结构"><a href="#Code-Outline：显示代码结构" class="headerlink" title="Code Outline：显示代码结构"></a>Code Outline：显示代码结构</h3><p>安装好插件「Code Outline」后，可以在左侧的资源管理器中，显示当前文件的代码结构：</p>
<p><img  srcset="data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20300%20300'%3E%3C/svg%3E" data-src="http://img.smyhvae.com/20180420_0925.png" class="lozad post-image"src="http://img.smyhvae.com/20180420_0925.png"></p>
<p>参考链接：</p>
<ul>
<li><p><a target="_blank" rel="noopener" href="https://www.zhihu.com/question/50273450">https://www.zhihu.com/question/50273450</a></p>
</li>
<li><p><a target="_blank" rel="noopener" href="http://itopic.org/vscode.html">http://itopic.org/vscode.html</a></p>
</li>
<li><p><a target="_blank" rel="noopener" href="https://github.com/varHarrie/varharrie.github.io/issues/10">https://github.com/varHarrie/varharrie.github.io/issues/10</a></p>
</li>
</ul>
<h3 id="vscode-fileheader：添加顶部注释模板-签名"><a href="#vscode-fileheader：添加顶部注释模板-签名" class="headerlink" title="vscode-fileheader：添加顶部注释模板(签名)"></a>vscode-fileheader：添加顶部注释模板(签名)</h3><p>（1）安装插件vscode -fileheader，并重启。</p>
<p>（2）在首选项-》设置-》中搜索fileheader，找到头部模板修改。</p>
<p>默认的快捷键是：「Ctrl + option + I」。</p>
<p>参考链接：</p>
<ul>
<li><a target="_blank" rel="noopener" href="https://www.zhihu.com/question/62385647">https://www.zhihu.com/question/62385647</a></li>
</ul>
<h3 id="Express"><a href="#Express" class="headerlink" title="Express"></a>Express</h3><p>在本地开启Node服务器：</p>
<p><img  srcset="data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20300%20300'%3E%3C/svg%3E" data-src="http://img.smyhvae.com/20180611_2230.png" class="lozad post-image"src="http://img.smyhvae.com/20180611_2230.png"></p>
<p>然后在浏览器的地址栏输入<code>http://localhost/</code> + 文件的相对路径，就可以通过服务器的形式打开这个文件。</p>
<h3 id="Copy-Relative-Path"><a href="#Copy-Relative-Path" class="headerlink" title="Copy Relative Path"></a>Copy Relative Path</h3><blockquote>
<p>这个插件很有用，使用频率很高。</p>
</blockquote>
<p>复制文件的相对路径：（相对于根路径而言）</p>
<p><img  srcset="data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20300%20300'%3E%3C/svg%3E" data-src="http://img.smyhvae.com/20180611_2235.png" class="lozad post-image"src="http://img.smyhvae.com/20180611_2235.png"></p>
<h3 id="open-in-browser"><a href="#open-in-browser" class="headerlink" title="open in browser"></a>open in browser</h3><p>在浏览器中打开。</p>
<h3 id="Auto-Rename-Tag"><a href="#Auto-Rename-Tag" class="headerlink" title="Auto Rename Tag"></a>Auto Rename Tag</h3><p>适用于 JSX、Vue、HTML。在修改标签名时，能在你修改开始（结束）标签的时候修改对应的结束（开始）标签，帮你减少 50% 的击键。</p>
<p>###Project Manager</p>
<p>项目管理，让我们方便的在命令面板中切换项目文件夹，当然，你也可以直接打开包含多个项目的父级文件夹，但这样可能会让 VSCode 变慢。</p>
<h3 id="highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】"><a href="#highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】" class="headerlink" title="highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】"></a>highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】</h3><p>VSCode自带的高亮显示，实在是不够显眼。用插件支持一下吧。</p>
<p>所用了这个插件之后，VS Code自带的高亮就可以关掉了：</p>
<p>在用户设置里添加<code>&quot;editor.selectionHighlight&quot;: false</code>即可。</p>
<p>参考链接：<a target="_blank" rel="noopener" href="https://blog.csdn.net/palmer_kai/article/details/79548164">vscode 选中后相同内容高亮插件推荐</a></p>
<h3 id="highlight-words：全局高亮（跨文件多色彩）"><a href="#highlight-words：全局高亮（跨文件多色彩）" class="headerlink" title="highlight-words：全局高亮（跨文件多色彩）"></a>highlight-words：全局高亮（跨文件多色彩）</h3><p>参考链接：<a target="_blank" rel="noopener" href="https://zhuanlan.zhihu.com/p/31163793">Visual Studio Code全局高亮着色插件(跨文件多色彩)经验纪要</a></p>
<h3 id="color-exchange：颜色格式转换【荐】"><a href="#color-exchange：颜色格式转换【荐】" class="headerlink" title="color-exchange：颜色格式转换【荐】"></a>color-exchange：颜色格式转换【荐】</h3><p>安装完插件后，在css中输入颜色，然后按<code>cmd + .</code>，就能进行颜色的格式转换。</p>
<p>20181013_1450.png</p>
<p>我在写这一段时，安装的人还不多，赶紧上车。</p>
<h2 id="Vue-相关的插件"><a href="#Vue-相关的插件" class="headerlink" title="Vue 相关的插件"></a>Vue 相关的插件</h2><h3 id="vetur：vue-文件的基本语法高亮"><a href="#vetur：vue-文件的基本语法高亮" class="headerlink" title="vetur：vue 文件的基本语法高亮"></a>vetur：vue 文件的基本语法高亮</h3><p>安装完 vetur 后还需要加上这样一段配置下：</p>
<pre class="highlight"><span class="line">&quot;emmet.syntaxProfiles&quot;: &#123;</span><br><span class="line">  &quot;vue-html&quot;: &quot;html&quot;,</span><br><span class="line">  &quot;vue&quot;: &quot;html&quot;</span><br><span class="line">&#125;</span><br></pre>

<p>参考链接：</p>
<ul>
<li><p><a target="_blank" rel="noopener" href="https://www.clarencep.com/2017/03/18/edit-vue-file-via-vscode/">https://www.clarencep.com/2017/03/18/edit-vue-file-via-vscode/</a></p>
</li>
<li><p><a target="_blank" rel="noopener" href="https://github.com/varHarrie/varharrie.github.io/issues/10">https://github.com/varHarrie/varharrie.github.io/issues/10</a></p>
</li>
</ul>
<h3 id="参考链接"><a href="#参考链接" class="headerlink" title="参考链接"></a>参考链接</h3><ul>
<li><p><a target="_blank" rel="noopener" href="https://www.jianshu.com/p/0724921285d4">https://www.jianshu.com/p/0724921285d4</a></p>
</li>
<li><p><a target="_blank" rel="noopener" href="https://www.cnblogs.com/AmosLee94/p/8338013.html">https://www.cnblogs.com/AmosLee94/p/8338013.html</a></p>
</li>
</ul>
<h2 id="常用快捷键"><a href="#常用快捷键" class="headerlink" title="常用快捷键"></a>常用快捷键</h2><table>
<thead>
<tr>
<th align="left">Win快捷键</th>
<th align="left">Mac快捷键</th>
<th align="left">作用</th>
<th align="left">备注</th>
</tr>
</thead>
<tbody><tr>
<td align="left">Shift + Alt + F</td>
<td align="left">Shift + option + F</td>
<td align="left">代码格式化</td>
<td align="left"></td>
</tr>
<tr>
<td align="left">Ctrl + Shift + N</td>
<td align="left"></td>
<td align="left">在当前行上面增加一行并跳至该行</td>
<td align="left"></td>
</tr>
<tr>
<td align="left"><strong>Ctrl + Shift + D</strong></td>
<td align="left"></td>
<td align="left">复制当前行到下一行</td>
<td align="left"></td>
</tr>
</tbody></table>
<h3 id="如何同时打开多个窗口"><a href="#如何同时打开多个窗口" class="headerlink" title="如何同时打开多个窗口"></a>如何同时打开多个窗口</h3><h2 id="问题"><a href="#问题" class="headerlink" title="问题"></a>问题</h2><p>问题1</p>
<p>解决；You can kill the Microsoft.VSCode.Cpp.IntelliSense.Msvc process to save the file successfully. 也就是 IntelliSense 这个进程。</p>
<h2 id="参考链接-1"><a href="#参考链接-1" class="headerlink" title="参考链接"></a>参考链接</h2><ul>
<li><a target="_blank" rel="noopener" href="https://zhuanlan.zhihu.com/p/30976584">能让你开发效率翻倍的 VSCode 插件配置（上）</a></li>
</ul>
<h3 id="某网友的VS-Code-插件截图"><a href="#某网友的VS-Code-插件截图" class="headerlink" title="某网友的VS Code 插件截图"></a>某网友的VS Code 插件截图</h3><p><img  srcset="data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20300%20300'%3E%3C/svg%3E" data-src="http://img.smyhvae.com/20180611_2255.png" class="lozad post-image"src="http://img.smyhvae.com/20180611_2255.png"></p>

  </div>
  <div>
    
      <div 
        class="post-note note-warning copyright" 
        style="margin-top: 42px">
        <p>
          <span style="font-weight: bold;">作者：</span><a 
            target="_blank" 
            rel="nofollow noopener noreferrer" 
            href="/about">
            zwl5670
          </a>
        </p>
        <p>
          <span style="font-weight: bold;">文章链接：</span><a 
            target="_blank" 
            rel="nofollow noopener noreferrer" 
            href="https://zwl5670.gitee.io/2000/01/01/00-%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/VS%20Code%E7%9A%84%E4%BD%BF%E7%94%A8%E7%A7%AF%E7%B4%AF/">
            https://zwl5670.gitee.io/2000/01/01/00-%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/VS%20Code%E7%9A%84%E4%BD%BF%E7%94%A8%E7%A7%AF%E7%B4%AF/
          </a>
        </p>
        <p><span style="font-weight: bold;">版权声明：</span>本博客所有文章除特别声明外，均采用<a target="_blank" rel="noopener" href="https://creativecommons.org/licenses/by-nc-sa/4.0/deed.zh">CC BY-NC-SA 4.0 协议</a>。转载请注明出处！</p>
      </div>
    
  </div>
</article>
<div class="nav">
  
    <div class="nav-item-prev">
      <a 
        href="/2000/01/01/00-%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/Atom%E5%9C%A8%E5%89%8D%E7%AB%AF%E7%9A%84%E4%BD%BF%E7%94%A8/" 
        class="nav-link">
        <i class="iconfont icon-left nav-prev-icon"></i>
        <div>
          <div class="nav-label">上一篇</div>
          
            <div class="nav-title">Atom在前端的使用 </div>
          
        </div>
      </a>
    </div>
  
  
    <div class="nav-item-next">
      <a 
        href="/2000/01/01/00-%E5%89%8D%E7%AB%AF%E5%B7%A5%E5%85%B7/chrome%E6%B5%8F%E8%A7%88%E5%99%A8/" 
        class="nav-link">
        <div>
          <div class="nav-label">下一篇</div>
          
            <div class="nav-title">chrome浏览器 </div>
          
        </div>
        <i class="iconfont icon-right nav-next-icon"></i>
      </a>
    </div>
  
</div>

<div 
  class="card card-content toc-card" 
  id="mobiletoc">
  <div class="toc-header">
  <i 
    class="iconfont icon-menu" 
    style="padding-right: 2px;">
  </i>目录
</div>
<ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E8%A7%81%E9%85%8D%E7%BD%AE"><span class="toc-text">常见配置</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E8%A7%81%E6%93%8D%E4%BD%9C"><span class="toc-text">常见操作</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%A6%82%E4%BD%95%E6%9F%A5%E7%9C%8B%E4%BB%A3%E7%A0%81%E7%BB%93%E6%9E%84"><span class="toc-text">如何查看代码结构</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%9C%A8%E6%9C%AC%E5%9C%B0%E5%BC%80%E5%90%AF%E6%9C%8D%E5%8A%A1%E5%99%A8"><span class="toc-text">在本地开启服务器</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E7%94%A8%E6%8F%92%E4%BB%B6"><span class="toc-text">常用插件</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#sftp%EF%BC%9A%E6%96%87%E4%BB%B6%E4%BC%A0%E8%BE%93"><span class="toc-text">sftp：文件传输</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Sass-Formatter"><span class="toc-text">Sass Formatter</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Code-Outline%EF%BC%9A%E6%98%BE%E7%A4%BA%E4%BB%A3%E7%A0%81%E7%BB%93%E6%9E%84"><span class="toc-text">Code Outline：显示代码结构</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#vscode-fileheader%EF%BC%9A%E6%B7%BB%E5%8A%A0%E9%A1%B6%E9%83%A8%E6%B3%A8%E9%87%8A%E6%A8%A1%E6%9D%BF-%E7%AD%BE%E5%90%8D"><span class="toc-text">vscode-fileheader：添加顶部注释模板(签名)</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Express"><span class="toc-text">Express</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Copy-Relative-Path"><span class="toc-text">Copy Relative Path</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#open-in-browser"><span class="toc-text">open in browser</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Auto-Rename-Tag"><span class="toc-text">Auto Rename Tag</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#highlight-icemode%EF%BC%9A%E9%80%89%E4%B8%AD%E7%9B%B8%E5%90%8C%E7%9A%84%E4%BB%A3%E7%A0%81%E6%97%B6%EF%BC%8C%E8%AE%A9%E9%AB%98%E4%BA%AE%E6%98%BE%E7%A4%BA%E6%9B%B4%E5%8A%A0%E6%98%8E%E6%98%BE%E3%80%90%E8%8D%90%E3%80%91"><span class="toc-text">highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#highlight-words%EF%BC%9A%E5%85%A8%E5%B1%80%E9%AB%98%E4%BA%AE%EF%BC%88%E8%B7%A8%E6%96%87%E4%BB%B6%E5%A4%9A%E8%89%B2%E5%BD%A9%EF%BC%89"><span class="toc-text">highlight-words：全局高亮（跨文件多色彩）</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#color-exchange%EF%BC%9A%E9%A2%9C%E8%89%B2%E6%A0%BC%E5%BC%8F%E8%BD%AC%E6%8D%A2%E3%80%90%E8%8D%90%E3%80%91"><span class="toc-text">color-exchange：颜色格式转换【荐】</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#Vue-%E7%9B%B8%E5%85%B3%E7%9A%84%E6%8F%92%E4%BB%B6"><span class="toc-text">Vue 相关的插件</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#vetur%EF%BC%9Avue-%E6%96%87%E4%BB%B6%E7%9A%84%E5%9F%BA%E6%9C%AC%E8%AF%AD%E6%B3%95%E9%AB%98%E4%BA%AE"><span class="toc-text">vetur：vue 文件的基本语法高亮</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%8F%82%E8%80%83%E9%93%BE%E6%8E%A5"><span class="toc-text">参考链接</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E7%94%A8%E5%BF%AB%E6%8D%B7%E9%94%AE"><span class="toc-text">常用快捷键</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%A6%82%E4%BD%95%E5%90%8C%E6%97%B6%E6%89%93%E5%BC%80%E5%A4%9A%E4%B8%AA%E7%AA%97%E5%8F%A3"><span class="toc-text">如何同时打开多个窗口</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E9%97%AE%E9%A2%98"><span class="toc-text">问题</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%8F%82%E8%80%83%E9%93%BE%E6%8E%A5-1"><span class="toc-text">参考链接</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%9F%90%E7%BD%91%E5%8F%8B%E7%9A%84VS-Code-%E6%8F%92%E4%BB%B6%E6%88%AA%E5%9B%BE"><span class="toc-text">某网友的VS Code 插件截图</span></a></li></ol></li></ol>
</div>
            </main>
            <aside class="right-column">
              <div class="sticky-widescreen">
  
  
    <article class="card card-content toc-card">
      <div class="toc-header">
  <i 
    class="iconfont icon-menu" 
    style="padding-right: 2px;">
  </i>目录
</div>
<ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E8%A7%81%E9%85%8D%E7%BD%AE"><span class="toc-text">常见配置</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E8%A7%81%E6%93%8D%E4%BD%9C"><span class="toc-text">常见操作</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%A6%82%E4%BD%95%E6%9F%A5%E7%9C%8B%E4%BB%A3%E7%A0%81%E7%BB%93%E6%9E%84"><span class="toc-text">如何查看代码结构</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%9C%A8%E6%9C%AC%E5%9C%B0%E5%BC%80%E5%90%AF%E6%9C%8D%E5%8A%A1%E5%99%A8"><span class="toc-text">在本地开启服务器</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E7%94%A8%E6%8F%92%E4%BB%B6"><span class="toc-text">常用插件</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#sftp%EF%BC%9A%E6%96%87%E4%BB%B6%E4%BC%A0%E8%BE%93"><span class="toc-text">sftp：文件传输</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Sass-Formatter"><span class="toc-text">Sass Formatter</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Code-Outline%EF%BC%9A%E6%98%BE%E7%A4%BA%E4%BB%A3%E7%A0%81%E7%BB%93%E6%9E%84"><span class="toc-text">Code Outline：显示代码结构</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#vscode-fileheader%EF%BC%9A%E6%B7%BB%E5%8A%A0%E9%A1%B6%E9%83%A8%E6%B3%A8%E9%87%8A%E6%A8%A1%E6%9D%BF-%E7%AD%BE%E5%90%8D"><span class="toc-text">vscode-fileheader：添加顶部注释模板(签名)</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Express"><span class="toc-text">Express</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Copy-Relative-Path"><span class="toc-text">Copy Relative Path</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#open-in-browser"><span class="toc-text">open in browser</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Auto-Rename-Tag"><span class="toc-text">Auto Rename Tag</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#highlight-icemode%EF%BC%9A%E9%80%89%E4%B8%AD%E7%9B%B8%E5%90%8C%E7%9A%84%E4%BB%A3%E7%A0%81%E6%97%B6%EF%BC%8C%E8%AE%A9%E9%AB%98%E4%BA%AE%E6%98%BE%E7%A4%BA%E6%9B%B4%E5%8A%A0%E6%98%8E%E6%98%BE%E3%80%90%E8%8D%90%E3%80%91"><span class="toc-text">highlight-icemode：选中相同的代码时，让高亮显示更加明显【荐】</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#highlight-words%EF%BC%9A%E5%85%A8%E5%B1%80%E9%AB%98%E4%BA%AE%EF%BC%88%E8%B7%A8%E6%96%87%E4%BB%B6%E5%A4%9A%E8%89%B2%E5%BD%A9%EF%BC%89"><span class="toc-text">highlight-words：全局高亮（跨文件多色彩）</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#color-exchange%EF%BC%9A%E9%A2%9C%E8%89%B2%E6%A0%BC%E5%BC%8F%E8%BD%AC%E6%8D%A2%E3%80%90%E8%8D%90%E3%80%91"><span class="toc-text">color-exchange：颜色格式转换【荐】</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#Vue-%E7%9B%B8%E5%85%B3%E7%9A%84%E6%8F%92%E4%BB%B6"><span class="toc-text">Vue 相关的插件</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#vetur%EF%BC%9Avue-%E6%96%87%E4%BB%B6%E7%9A%84%E5%9F%BA%E6%9C%AC%E8%AF%AD%E6%B3%95%E9%AB%98%E4%BA%AE"><span class="toc-text">vetur：vue 文件的基本语法高亮</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%8F%82%E8%80%83%E9%93%BE%E6%8E%A5"><span class="toc-text">参考链接</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%B8%B8%E7%94%A8%E5%BF%AB%E6%8D%B7%E9%94%AE"><span class="toc-text">常用快捷键</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%A6%82%E4%BD%95%E5%90%8C%E6%97%B6%E6%89%93%E5%BC%80%E5%A4%9A%E4%B8%AA%E7%AA%97%E5%8F%A3"><span class="toc-text">如何同时打开多个窗口</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E9%97%AE%E9%A2%98"><span class="toc-text">问题</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E5%8F%82%E8%80%83%E9%93%BE%E6%8E%A5-1"><span class="toc-text">参考链接</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%9F%90%E7%BD%91%E5%8F%8B%E7%9A%84VS-Code-%E6%8F%92%E4%BB%B6%E6%88%AA%E5%9B%BE"><span class="toc-text">某网友的VS Code 插件截图</span></a></li></ol></li></ol>
    </article>
  
  
  <article class="card card-content">
    <div class="recent-posts-card">
  <div class="recent-posts-header">
    <i 
      class="iconfont icon-wenzhang_huaban" 
      style="padding-right: 2px;">
    </i>最近文章
  </div>
  <div class="recent-posts-list">
    
      <div class="recent-posts-item">
        <div class="recent-posts-item-title">2023-03-09</div>
        <a href="/2023/03/09/13-React%E5%9F%BA%E7%A1%80/11-React%20Navive%E5%88%9D%E8%AF%86/"><div class="recent-posts-item-content">11-React Navive初识</div></a>
      </div>
    
      <div class="recent-posts-item">
        <div class="recent-posts-item-title">2023-03-09</div>
        <a href="/2023/03/09/13-React%E5%9F%BA%E7%A1%80/10-AntD%E6%A1%86%E6%9E%B6%E7%9A%84upload%E7%BB%84%E4%BB%B6%E4%B8%8A%E4%BC%A0%E5%9B%BE%E7%89%87%E6%97%B6%E4%BD%BF%E7%94%A8customRequest%E6%96%B9%E6%B3%95%E8%87%AA%E5%AE%9A%E4%B9%89%E4%B8%8A%E4%BC%A0%E8%A1%8C%E4%B8%BA/"><div class="recent-posts-item-content">10-AntD框架的upload组件上传图片时使用customRequest方法自定义上传行为</div></a>
      </div>
    
      <div class="recent-posts-item">
        <div class="recent-posts-item-title">2023-03-09</div>
        <a href="/2023/03/09/13-React%E5%9F%BA%E7%A1%80/09-AntD%E6%A1%86%E6%9E%B6%E7%9A%84upload%E7%BB%84%E4%BB%B6%E4%B8%8A%E4%BC%A0%E5%9B%BE%E7%89%87%E6%97%B6%E9%81%87%E5%88%B0%E7%9A%84%E4%B8%80%E4%BA%9B%E5%9D%91/"><div class="recent-posts-item-content">09-AntD框架的upload组件上传图片时遇到的一些坑</div></a>
      </div>
    
      <div class="recent-posts-item">
        <div class="recent-posts-item-title">2023-03-09</div>
        <a href="/2023/03/09/13-React%E5%9F%BA%E7%A1%80/08-Ant%20Design%E7%9A%84%E5%9F%BA%E6%9C%AC%E4%BD%BF%E7%94%A8/"><div class="recent-posts-item-content">08-Ant Design的基本使用</div></a>
      </div>
    
  </div>
</div>
  </article>
  
  
</div>
            </aside>
          </div>
        </div>
      </div>
    </div>
     
    <footer class="footer">
  <div class="footer-container">
    <div>
      <div class="footer-dsc">
        <span>
          Copyright ©
          
            2023
          
          
        </span>
        &nbsp;
        <a 
          href="/" 
          class="footer-link">
          前端面试
        </a>
      </div>
    </div>

    
      <div class="footer-dsc">
        
          Powered by
          <a 
            href="https://hexo.io/" 
            class="footer-link" 
            target="_blank" 
            rel="nofollow noopener noreferrer">
            &nbsp;Hexo
          </a>
        
        
          <span>&nbsp;|&nbsp;</span>
        
        
          Theme -
          <a 
            href="https://github.com/theme-kaze" 
            class="footer-link" 
            target="_blank"
            rel="nofollow noopener noreferrer">
            &nbsp;Kaze
          </a>
        
      </div>
    
    
    
    
</footer>
 
    
  <a 
    role="button" 
    id="scrollbutton" 
    class="basebutton" 
    aria-label="回到顶部">
    <i class="iconfont icon-arrowleft button-icon"></i>
  </a>

<a 
  role="button" 
  id="menubutton"
  aria-label="menu button"
  class="basebutton">
  <i class="iconfont icon-menu button-icon"></i>
</a>
<a 
  role="button" 
  id="popbutton" 
  class="basebutton" 
  aria-label="控制中心">
  <i class="iconfont icon-expand button-icon"></i>
</a>
<a 
  role="button" 
  id="darkbutton" 
  class="basebutton darkwidget" 
  aria-label="夜色模式">
  <i class="iconfont icon-weather button-icon"></i>
</a>
<a 
  role="button" 
  id="searchbutton" 
  class="basebutton searchwidget" 
  aria-label="搜索">
  <i class="iconfont icon-search button-icon"></i>
</a> 
     
     
     
      <script>
  var addImgLayout = function () {
    var img = document.querySelectorAll('.post-content img')
    var i
    for (i = 0; i < img.length; i++) {
      var wrapper = document.createElement('a')
      wrapper.setAttribute('href', img[i].getAttribute('data-src'))
      wrapper.setAttribute('aria-label', 'illustration')
      wrapper.style.cssText =
        'width: 100%; display: flex; justify-content: center;'
      if (img[i].alt) wrapper.dataset.caption = img[i].alt
      wrapper.dataset.nolink = true
      img[i].before(wrapper)
      wrapper.append(img[i])
      var divWrap = document.createElement('div')
      divWrap.classList.add('gallery')
      wrapper.before(divWrap)
      divWrap.append(wrapper)
    }
    baguetteBox.run('.gallery')
  }
</script>
<script>
  loadScript(
    "/js/lib/lightbox/baguetteBox.min.js",
    addImgLayout
  )
</script>
 
     
     
    <script src="/js/main.js"></script> 
     
    
      <script>
        var addLazyload = function () {
          var observer = lozad('.lozad', {
            load: function (el) {
              el.srcset = el.getAttribute('data-src')
            },
            loaded: function (el) {
              el.classList.add('loaded')
            },
          })
          observer.observe()
        }
      </script>
      <script>
        loadScript('/js/lib/lozad.min.js', addLazyload)
      </script>
    
    <script src="//instant.page/5.1.0" type="module"
      integrity="sha384-by67kQnR+pyfy8yWP4kPO12fHKRLHZPfEsiSXR8u2IKcTdxD805MGUXBzVPnkLHw"></script>
    
    
  </body>
</html>
